package com.lagou.zxy.config;

/**
 * @program: stage-4-module-3
 * @description:
 * @author: zhangxiaoyang
 * @date: 11/24/20 4:14 PM
 **/
import com.mongodb.MongoClientOptions;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class MongoDbSettings {

    @Bean
    public MongoClientOptions mongoOptions() {
        return MongoClientOptions
                .builder()
                .maxConnectionIdleTime(60000)
                .build();
    }

}